'''
function:
根据预设输入的时间，提醒今天或者这周要关注什么
'''
import daily_reminder as dr
import major_country_interest_rate_crawler as mcirc
import world_government_bonds_crawler as wgbc
import world_stock_futures_FX_cybermoney as sffc
import China_gold as cg
import Gold_sliver as gs
import China_CPI as cc
import RMB_trend as rt
import screenshot as ss
import VIX as VIX
import ETF as ETF

import time  
from selenium import webdriver  
import re,os



print('\n每日提醒\n')
dr.reminder()
dr.qihuojiesuan_reminder() #股指期货交割日提醒
dr.huangjinjiaoge_reminder() #黄金结算日
dr.yuexian_reminder() #月线提醒

driver = webdriver.Chrome(r'F:\Python\Economic\chromedriver_win32\chromedriver.exe')  #打开浏览器
#driver对象调用maximize_window()方法最大化浏览器窗口
driver.maximize_window()

print('\n黄金白银ETF持仓情况\n')
ETF.ETF(driver)
ss.get_screen_shot('黄金ETF '+time.strftime("%Y-%m-%d", time.localtime()))
ETF.ETF(driver,'silver')
ss.get_screen_shot('白银ETF '+time.strftime("%Y-%m-%d", time.localtime()))

print('\n金银比\n')
gs.Gold_divided_by_silver(driver)
ss.get_screen_shot('金银比 '+time.strftime("%Y-%m-%d", time.localtime()))

print('\n国家利率\n')
mcirc.batch_check_interest_rate(driver)
ss.get_screen_shot('国家利率 '+time.strftime("%Y-%m-%d", time.localtime()))

print('\n国家债券\n')
wgbc.batch_check_bonds_rate(driver)
ss.get_screen_shot('国家债券 '+time.strftime("%Y-%m-%d", time.localtime()))

print('\n环球股市、期货、汇率、电子货币走势：\n')
sffc.batch_check_stock_futures_FX_cybermoney(driver)

print('\n中国黄金储备\n')
cg.China_gold_stock(driver)
ss.get_screen_shot('中国黄金储备 '+time.strftime("%Y-%m-%d", time.localtime()))

print('\n中国CPI指数\n')
cc.China_CPI(driver)
ss.get_screen_shot('中国CPI指数 '+time.strftime("%Y-%m-%d", time.localtime()))

print('\nRMB综合指数\n')
rt.China_RMB(driver)
ss.get_screen_shot('RMB综合指数 '+time.strftime("%Y-%m-%d", time.localtime()))

print('\nVIX恐惧指数\n')
VIX.VIX(driver)
ss.get_screen_shot('VIX恐惧指数 '+time.strftime("%Y-%m-%d", time.localtime()))

driver.get('http://data.eastmoney.com/report/orgpublish.jshtml?orgcode=80000214')

print('\n即将为您打开图片所在地址\n')
Obj='F:\Python\Economic\daily screenshot'
os.startfile(str(Obj))

#driver.quit()

